package day240512.p;

public class Dog  {
    String name;
    double weight;
    public Dog(String name,double weight){
        this.name=name;
        this.weight=weight;

    }
    public String toString(){
        return this.name + "(" + this.weight + ")";
    }

    /*public int compareTo(Object o) {
        Dog d = (Dog) o;
        if (this.weight == d.weight) {
            return 0;
        } else if (this.weight > d.weight) {
            return 1;
        } else {
            return -1;
        }


    }*/


}
